package org.rosildos.ricotta.dao.hibernate;

import org.apache.log4j.Logger;
import org.hibernate.Query;
import org.hibernate.Session;
import org.rosildos.ricotta.dao.UserDao;
import org.rosildos.ricotta.model.User;

public class HibernateUserDao implements UserDao {
	
	private static Logger logger = Logger.getLogger(HibernateUserDao.class);
	
	private Session session;

	public User findUserByUserNameOrEmail(String item) {
		logger.debug("looking for user by either username or email [" + item + "]");
		Query query = session.createQuery("from user where userName = ? or email = ?");
		return null;
	}

	public User findUserByUserName(String username) {
		// TODO Auto-generated method stub
		return null;
	}

	public User findUserByEmail(String email) {
		// TODO Auto-generated method stub
		return null;
	}

	public Session getSession() {
		return session;
	}

	public void setSession(Session session) {
		this.session = session;
	}
		
}
